import request from '@/utils/request'

// 查询实验室黑名单列表
export function listBlacklist(query) {
  return request({
    url: '/labdata/blacklist/list',
    method: 'get',
    params: query
  })
}
export function listBlackUsers(query) {
  return request({
    url: '/labdata/blacklist/userlist',
    method: 'get',
    params: query
  })
}

//getBlackUserInfo
export function getBlackUserInfo(userBlackId) {
  return request({
    url: '/labdata/blacklist/getBlackUserInfo/' + userBlackId,
    method: 'get'
  })
}

// 查询实验室黑名单详细
export function getBlacklist(blacklistId) {
  return request({
    url: '/labdata/blacklist/' + blacklistId,
    method: 'get'
  })
}

// 新增实验室黑名单
export function addBlacklist(data) {
  return request({
    url: '/labdata/blacklist',
    method: 'post',
    data: data
  })
}

// 修改实验室黑名单
export function updateBlacklist(data) {
  return request({
    url: '/labdata/blacklist',
    method: 'put',
    data: data
  })
}

// 删除实验室黑名单
export function delBlacklist(blacklistId) {
  return request({
    url: '/labdata/blacklist/' + blacklistId,
    method: 'delete'
  })
}

// 导出实验室黑名单
export function exportBlacklist(query) {
  return request({
    url: '/labdata/blacklist/export',
    method: 'get',
    params: query
  })
}
